package se.mbaeumer.tinydbc.core.server;

import java.util.ArrayList;
import java.util.List;

import se.mbaeumer.tinydbc.core.dbclient.AbstractDBClient;

public class DatabaseServer {
	private String serverName;
	private String serverAddress;
	private int port;
	private List<AbstractDBClient> databases;
	private AbstractDBClient currentDatabase;	
	private String username;
	private String password;
	private boolean isDefault;
	
	public String getServerName() {
		return serverName;
	}
	public void setServerName(String serverName) {
		this.serverName = serverName;
	}
	public String getServerAddress() {
		return serverAddress;
	}
	public void setServerAddress(String serverAddress) {
		this.serverAddress = serverAddress;
	}
	public int getPort() {
		return port;
	}
	public void setPort(int port) {
		this.port = port;
	}
	public List<AbstractDBClient> getDatabases() {
		return databases;
	}
	public void setDatabases(List<AbstractDBClient> databases) {
		this.databases = databases;
	}
	
	public DatabaseServer(String serverName, String serverAddress, int port){
		databases = new ArrayList<AbstractDBClient>();
		this.serverName = serverName;
		this.serverAddress = serverAddress;
		this.port = port;
	}
	public AbstractDBClient getCurrentDatabase() {
		return currentDatabase;
	}
	public void setCurrentDatabase(AbstractDBClient currentDatabase) {
		this.currentDatabase = currentDatabase;
	}
	public String getUsername() {
		return username;
	}
	public void setUsername(String username) {
		this.username = username;
	}
	public String getPassword() {
		return password;
	}
	public void setPassword(String password) {
		this.password = password;
	}
	public boolean isDefault() {
		return isDefault;
	}
	public void setDefault(boolean isDefault) {
		this.isDefault = isDefault;
	}
}
